score = eval(input())
if 90<=score<=100:
	print('A')
if 80<=score<90:
	print('B')
if 70<=score<80:
	print('C')
if 60<=score<70:
	print('D')
if 50<=score<60:
	print('F')
if score>100 or score<0:
	print('data error!')